<template>
    <div class="one-index">
        <div class="content">
            {{ props.data.name }}
            <span>{{ props.data.count }}</span>
            {{ props.data.unit }}
        </div>
    </div>
</template>

<script lang="ts" setup>
import { PropType } from 'vue'
interface dataInt {
    name: string
    count: number
    unit: string
}

const props = defineProps({
    data: {
        type: Object as PropType<dataInt>,
        default: () => {
            return {
                name: '响应率',
                count: 100,
                unit: '%'
            }
        }
    }
})
</script>

<style lang="scss" scoped>
.one-index {
    width: 100%;
    height: 68px;
    background: url('./image/statisticalData_bg@2x.png') no-repeat;
    background-size: 100% 100%;
    margin: 5px 0;
    .content {
        width: 100%;
        height: 28px;
        display: flex;
        align-items: flex-end;
        justify-content: center;
        font-family: 'OPPOSans';
        font-size: 18px;
        color: #ffffff;
        letter-spacing: 1px;
        text-align: center;
        span {
            font-family: 'Tencent';
            font-size: 36px;
            padding: 0 5px;
            color: #86dbff;
        }
    }
}
</style>
